Component({
  // 接受父组件的传值
  properties: {
    showPopup: Boolean,
    pickertype:'',
    columns: '',
  },
  data: {
  },
  methods: {
  // 提交时获取picker选择信息与父组件传来的pickertype,并将其返回,用于父组件做判断
  onConfirm(event) {
    const {value} = event.detail;
    this.triggerEvent('picker', {
      pickerdetail: `${value}`,
      pickertype:this.properties.pickertype
		})
    this.setData({ showPopup: false });
  },
  onCancel() {
    this.setData({ showPopup: false });
  },
  showPopup() {
    this.setData({ showPopup: true });
  },
  onClose() {
    this.setData({ showPopup: false });
  },
  }
})
